package com.glsc.ngateway.common.base.domain.mysql.opmanage.report.regulatory;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Data;

import javax.persistence.*;
import java.io.Serializable;
import java.math.BigInteger;
import java.util.Objects;

@Data
@Entity
@Table(name = "t_reg_rpt_nafmii_scale")
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties({"hibernateLazyInitializer", "handler"})
@ExcelIgnoreUnannotated
@IdClass(RegRptNAFMIIScale.PK.class)
public class RegRptNAFMIIScale {
    public static class PK implements Serializable {
        private BigInteger mainId;
        private BigInteger id;

        public BigInteger getMainId() {
            return mainId;
        }

        public void setMainId(BigInteger mainId) {
            this.mainId = mainId;
        }

        public BigInteger getId() {
            return id;
        }

        public void setId(BigInteger id) {
            this.id = id;
        }

        @Override
        public boolean equals(Object o) {
            if (this == o) {
                return true;
            }
            if (o == null || getClass() != o.getClass()) {
                return false;
            }
            PK pk = (PK) o;
            return Objects.equals(mainId, pk.mainId) && Objects.equals(id, pk.id);
        }

        @Override
        public int hashCode() {
            return Objects.hash(mainId, id);
        }
    }

    @Id
    @Column(name = "id")
    private BigInteger id;

    @Id
    @Column(name = "main_id")
    private BigInteger mainId;

    @ExcelProperty(index = 0)
    @Column(name = "fc_type")
    private String type;

    @ExcelProperty(index = 1)
    @Column(name = "ff_month_begin_remain")
    private Double monthBeginRemain;

    @ExcelProperty(index = 2)
    @Column(name = "ff_increased")
    private Double increased;

    @ExcelProperty(index = 3)
    @Column(name = "ff_end")
    private Double end;

    @ExcelProperty(index = 4)
    @Column(name = "ff_remain")
    private Double remain;

    @ExcelProperty(index = 5)
    @Column(name = "ff_year_increased")
    private Double yearIncreased;

    @ExcelProperty(index = 6)
    @Column(name = "ff_month_begin_remain_count")
    private Double monthBeginRemainCount;

    @ExcelProperty(index = 7)
    @Column(name = "ff_increased_count")
    private Double increasedCount;

    @ExcelProperty(index = 8)
    @Column(name = "ff_end_count")
    private Double endCount;

    @ExcelProperty(index = 9)
    @Column(name = "ff_remain_count")
    private Double remainCount;

    @ExcelProperty(index = 10)
    @Column(name = "ff_year_increased_count")
    private Double yearIncreasedCount;

    public void setType(String type) {
        this.type = type;
    }

    public String getType() {
        return type;
    }

    public Double getMonthBeginRemain() {
        return monthBeginRemain;
    }

    public void setMonthBeginRemain(Double monthBeginRemain) {
        this.monthBeginRemain = monthBeginRemain;
    }

    public Double getIncreased() {
        return increased;
    }

    public void setIncreased(Double increased) {
        this.increased = increased;
    }

    public Double getEnd() {
        return end;
    }

    public void setEnd(Double end) {
        this.end = end;
    }

    public Double getRemain() {
        return remain;
    }

    public void setRemain(Double remain) {
        this.remain = remain;
    }

    public Double getYearIncreased() {
        return yearIncreased;
    }

    public void setYearIncreased(Double yearIncreased) {
        this.yearIncreased = yearIncreased;
    }

    public Double getMonthBeginRemainCount() {
        return monthBeginRemainCount;
    }

    public void setMonthBeginRemainCount(Double monthBeginRemainCount) {
        this.monthBeginRemainCount = monthBeginRemainCount;
    }

    public Double getIncreasedCount() {
        return increasedCount;
    }

    public void setIncreasedCount(Double increasedCount) {
        this.increasedCount = increasedCount;
    }

    public Double getEndCount() {
        return endCount;
    }

    public void setEndCount(Double endCount) {
        this.endCount = endCount;
    }

    public Double getRemainCount() {
        return remainCount;
    }

    public void setRemainCount(Double remainCount) {
        this.remainCount = remainCount;
    }

    public Double getYearIncreasedCount() {
        return yearIncreasedCount;
    }

    public void setYearIncreasedCount(Double yearIncreasedCount) {
        this.yearIncreasedCount = yearIncreasedCount;
    }

    public void setMainId(BigInteger mainId) {
        this.mainId = mainId;
    }

    public BigInteger getMainId() {
        return mainId;
    }

    public BigInteger getId() {
        return id;
    }

    public void setId(BigInteger id) {
        this.id = id;
    }
}

